#ifndef GAMETD_STATUSBAR_H
#define GAMETD_STATUSBAR_H

#include <SDL.h>
#include <string>

class StatusBar {
public:
    StatusBar() = default;
    ~StatusBar() = default;
    void SetPosition(int x, int y);
    void OnUpdate(SDL_Renderer *renderer, double coinNum);
    void OnRender(SDL_Renderer *renderer, double currentHp);

private:
    const int sizeHeart = 32;
    const int widthMpBar = 200;
    const int heightMpBar = 20;
    const int widthBorderMpBar = 4;
    const SDL_Point offsetShadow = {2, 2};
    const SDL_Color colorTextBackground = {175, 175, 175, 255};
    const SDL_Color colorTextForeground = {255, 255, 255, 255};
    const SDL_Color colorMpBarBackground = {48, 40, 51, 255};
    const SDL_Color colorMpBarForeground = {144, 121, 173, 255};

private:
    SDL_Point position = {0};
    int widthText = 0, heightText = 0;
    SDL_Texture *texTextBackground = nullptr;
    SDL_Texture *texTextForeground = nullptr;
};


#endif //GAMETD_STATUSBAR_H
